import httpAxios from '../utils/httpAxios';

//创建获取数据接口
//获取验证码
export const getCaptchaImage = () => httpAxios.get('/dev-api/captchaImage');
//登录接口
export const login = (params) => httpAxios.post('/dev-api/login', params);
//获取岗位
export const getPostList = (params) => httpAxios.get('/dev-api/sxpt/station/selectStationLabel', { params });
//获取岗位列表
export const getPostVersionList = (params) => httpAxios.get('/dev-api/sypt/station/selectStationNewVersionList', { params });

export const inintList = () => httpAxios.get('/dev-api/sxpt/label/selectMajorStationList');

export const iniSetList = () => httpAxios.get('/dev-api/sxpt/label/selectTradeList');

export const list = (params) => httpAxios.get('/dev-api/sypt/project/list', { params });

export const getTrainingList = () => httpAxios.get('/dev-api/sxpt/progress/selectClassPlanByStu');

export const getUser = () => httpAxios.get('/dev-api/system/user/profile');

export const putUser = (params) => httpAxios.put('/dev-api/system/user/profile',params);

export const putPwd = (params) => httpAxios.put(`/dev-api/system/user/profile/updatePwd?oldPassword=${params.oldPassword}&newPassword=${params.newPassword}`);

export const putImg = (params) => httpAxios.post('/dev-api/system/user/profile/avatar',params);

export const getPostDetail = (params) => httpAxios.get('/dev-api/sxpt/station/selectStationListById/'+params.id);

export const getPostDetailList = (params) => httpAxios.get('/dev-api/sxpt/skill/selectSkillList',{params});

export const getNavDetail = (params) => httpAxios.get('/dev-api/sxpt/skill/selectSkillInfo/'+params.id);

export const searchNav = (params) => httpAxios.get('/dev-api/sxpt/skill/selectSkillList',{params});
//获取项目详情的评论接口
export const Pinglunx = (params) => httpAxios.get('/dev-api/sypt/discuss/list', { params });
//获取知道老师的请求
export const Terchang = (id) => httpAxios.get(`/dev-api/sypt/project/teacherInfo/${id}`);

export const itemimg = (id) => httpAxios.get(`/dev-api/sypt/project/taskInfo/${id}`);

export const SiXun = () => httpAxios.get(`/dev-api/sxpt/brief/selectBriefTree`);//实训大纲的请求

//实现问答的分页
export const FenteZ = (params) => httpAxios.get(`/dev-api/sypt/answer/list/project`, {params});

export const imaage = () => httpAxios.get(`/dev-api/getInfo`);//获取评论人的借口
//发起评论的接口
export const addpinglun=(params)=> httpAxios.post("/dev-api/sypt/discuss",params);


//教师端
export const getPostVersionList2 = (params) => httpAxios.get('/dev-api/sxpt/station/selectStationVersionList', { params });

export const getPostDetail2 = (params) => httpAxios.get('/dev-api/sxpt/station/selectStationListById/'+params.id);

export const deleteList = (params) => httpAxios.delete('/dev-api/sxpt/station/deleteStation',{params});

export const updateList = (params) => httpAxios.get('/dev-api/sxpt/station/updateStationStatusCancel',{params});

export const getDataList = (params) => httpAxios.get("/dev-api/sxpt/station/updateStationStatus",{params});